package com.cloud.api.domain.alarm;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.cloud.core.entity.base.BaseEntity;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Getter;
import lombok.Setter;
import lombok.experimental.Accessors;

import jakarta.validation.constraints.NotEmpty;
import jakarta.validation.constraints.NotNull;
import jakarta.validation.constraints.Size;
import java.io.Serializable;

/**
 * <p>
 * 
 * </p>
 *
 * @author haohaibo
 * @since 2024-02-21
 */
@Getter
@Setter
@Accessors(chain = true)
@TableName("t_alarm_category")
@Schema(name = "AlarmCategory", description = "")
public class AlarmCategory extends BaseEntity implements Serializable {

    private static final long serialVersionUID = 1L;

    @TableId("id")
//    @NotEmpty(message = "{validation.common.id}")
    private String id;

    @Schema(description = "报警类别名称")
    @TableField("category_name")
    @NotEmpty(message = "{validation.alarm.categoryName}")
    private String categoryName;

    @Schema(description = "协议类别： 1国标 2私有")
    @TableField("protocol_type")
    @NotNull(message = "{validation.alarm.protocolType}")
    private Integer protocolType;

    @Schema(description = "类别对应的code码")
    @TableField("code")
    @Size(max = 10,message = "{validation.common.maxSize}")
//    @NotEmpty(message = "{validation.alarm.code}")
    private String code;

    @Schema(description = "短信开启状态  0未开 1开启",hidden = true)
    @TableField("sms_status")
    private Integer smsStatus;

}
